import { translateTitle } from '@/utils/i18n'
const BusinessSystemRoleMenuButton = {
  BusinessSystemRoleMenuButton: {
    search: {
      form: {
        method: 'roleServiceImpl.queryRoleTable',
        name: 'search',
        field: [
          {
            type: 'input',
            name: 'ROLE_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.角色编码'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'ROLE_NAME',
            label: translateTitle('Dams.APIMinterfaceManagement.角色名称'),
            labelHidden: false,
          },
          {
            type: 'radio',
            name: 'ACTIVE_FLAG',
            label: translateTitle('Dams.APIMinterfaceManagement.活动标记'),
            labelHidden: false,
            options: [
              {
                LABEL: 'Y',
                CODE: 'Y',
              },
              {
                LABEL: 'N',
                CODE: 'N',
              },
            ],
          },
          {
            type: 'button',
            label: translateTitle('Dams.APIMinterfaceManagement.查询'),
            labelHidden: true,
          },
          {
            type: 'button',
            label: translateTitle('Dams.APIMinterfaceManagement.重置'),
            labelHidden: true,
          },
        ],
      },
    },
    dialog: {
      form: {
        api: '',
        name: 'dialog',
        field: [
          {
            type: 'checkbox',
            name: 'ID',
            label: '',
            hidden: true,
          },
          {
            type: 'input',
            name: 'ORG_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.组织ID'),
            hidden: true,
          },
          {
            type: 'input',
            name: 'ROLE_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.角色ID'),
            isRules: true,
            disabled_edit: true,
          },
          {
            type: 'input',
            name: 'ROLE_NAME',
            label: translateTitle('Dams.APIMinterfaceManagement.角色名称'),
            isRules: true,
            labelHidden: false,
          },
          {
            type: 'radio',
            name: 'ACTIVE_FLAG',
            label: translateTitle('Dams.APIMinterfaceManagement.激活标记'),
            isRules: true,
            labelHidden: false,
            value: 'Y',
            options: [
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.激活'),
                CODE: 'Y',
              },
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.未激活'),
                CODE: 'N',
              },
            ],
          },
          {
            type: 'radio',
            name: 'ADVANCE_FLAG',
            label: translateTitle('Dams.APIMinterfaceManagement.系统预制代码'),
            isRules: true,
            labelHidden: false,
            value: 'N',
            disabled_edit: true,
            disabled_add: true,
            options: [
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.是'),
                CODE: 'Y',
              },
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.否'),
                CODE: 'N',
              },
            ],
          },
          {
            type: 'input',
            name: 'NOTES',
            label: translateTitle('Dams.APIMinterfaceManagement.备注'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'USERDEFINED1',
            label: translateTitle('Dams.APIMinterfaceManagement.角色自定义1'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'USERDEFINED2',
            label: translateTitle('Dams.APIMinterfaceManagement.角色自定义2'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'USERDEFINED3',
            label: translateTitle('Dams.APIMinterfaceManagement.角色自定义3'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'USERDEFINED4',
            label: translateTitle('Dams.APIMinterfaceManagement.角色自定义4'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'USERDEFINED5',
            label: translateTitle('Dams.APIMinterfaceManagement.角色自定义5'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'ADDTIME',
            label: translateTitle('Dams.APIMinterfaceManagement.增加时间'),
            labelHidden: false,
            disabled_edit: true,
            disabled_add: true,
          },
          {
            type: 'input',
            name: 'ADDWHO',
            label: translateTitle('Dams.APIMinterfaceManagement.增加人'),
            labelHidden: false,
            disabled_edit: true,
            disabled_add: true,
          },
          {
            type: 'input',
            name: 'EDITTIME',
            label: translateTitle('Dams.APIMinterfaceManagement.修改时间'),
            labelHidden: false,
            disabled_edit: true,
            disabled_add: true,
          },
          {
            type: 'input',
            name: 'EDITWHO',
            label: translateTitle('Dams.APIMinterfaceManagement.修改人'),
            labelHidden: false,
            disabled_edit: true,
            disabled_add: true,
          },
          {
            type: 'button',
            label: translateTitle('Dams.APIMinterfaceManagement.提交'),
            labelHidden: true,
          },
        ],
      },
    },
    addMethod: 'roleServiceImpl.roleAdd',
    deleteMethod: 'roleServiceImpl.roleDeleteById',
    updateMethod: 'roleServiceImpl.roleUpdate',
    getJsonMethod: 'roleServiceImpl.queryRolePageJson',
    getMenuRoleMethod: 'roleServiceImpl.queryMenuByRoleId',
    saveRolePage: 'roleServiceImpl.addRolePage',
    savePageJson: 'roleServiceImpl.saveRolePageJson',
    queryUser: 'roleServiceImpl.queryUserIdByRoleId',
    saveUserRole: 'roleServiceImpl.addUserRole',
  },
}
export default BusinessSystemRoleMenuButton
